<?php
namespace data\model;

class Config extends BaseModel{
    const USER_CONFIG = 1;  //用户配置
    const WEB_CONFIG = 2; //网站配置

    public function updateConfig($key,$value){
        $config = $this->where('key','=',$key)->find();
        $config->value = $value;
        $config->save();
    }
}